<#assign domain="${ctx.contextPath}" />
<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<meta http-equiv="x-ua-compatible" content="IE=Edge, chrome=1"/>
	<meta name="renderer" content="webkit">
	<title>scoreCard2</title>
		<link rel="stylesheet" href="${domain}/static/css/common/bootstrap.min.css">
	<link rel="stylesheet" href="${domain}/static/css/common/base.css">
	<link rel="stylesheet" href="${domain}/static/css/common/header.css">
	<link rel="stylesheet" href="${domain}/static/css/antiFraud.css">
	<script src="${domain}/static/js/jquery-3.2.1.slim.min.js"></script>
	<script src="${domain}/static/js/bootstrap.min.js"></script
	<script src="${domain}/static/js/jquery-3.2.1.min.js"></script>
	<script src="${domain}/static/js/bootstrap.min.js"></script>
	 <link rel="stylesheet" href="${domain}/static/css/bootstrap.css">
	  <link rel="stylesheet" href="${domain}/static/css/bootstrapValidator.css">
	 <script src="${domain}/static/js/bootstrapValidator.js"></script>
</head>

<div class="content">
		<!--侧边导航-->
		<!--反欺诈内容-->
		<div class="anti-fraud">
			<div class="wrap">
				   <form id="defaultForm" method="post" class="form-horizontal" action="${domain}/nut/setCyber">
                             <h1>请选择查询银行卡</h1>
                             
                            <div class="form-group">
							<select class="form-control" name="loginTarget" id="loginTarget">
							<option value="">全部</option>
							<option value="1">信用卡</option>
					        <option value="2">储蓄卡</option>
							</select>
						</div>
						 <div class="form-group">
							<select class="form-control" name="taskSubType" id="taskSubType">
						<option value="">请选择</option>
							</select>
						</div>
						<input type="hidden" class="form-control" placeholder="accessToken" name="accessToken" id="accessToken">
                         
<div name="signup">
           <button type="submit" class="btn btn-primary" style="width:200px;margin:0 auto;display:block;">查询</button>
</div>
                    </form>
			</div>
		</div>
	</div>

<script>

 $(document).ready(function() {

    $('#defaultForm').bootstrapValidator({
//        live: 'disabled',
        message: 'This value is not valid',
        feedbackIcons: {
            valid: 'glyphicon glyphicon-ok',
            invalid: 'glyphicon glyphicon-remove',
            validating: 'glyphicon glyphicon-refresh'
        },
        fields: {
            taskSubType: {
                group: '.form-group',
                validators: {
                    notEmpty: {
                        message: '请输入查询类型'
                    },
                        stringLength: {/*长度提示*/
                            min: 1,
                            max: 30,
                            message: '输入长度过长'
                        }
                }
            }
        }
    });
});


$.ajax({
                cache: true,
                type: "POST",
                url:"../nut/getBankList",
                data:null,
                async: false,
                error: function(request) {
                },
                success: function(data) {
               $("#accessToken").val(data.accessToken);
                for(var i=0;i<data.taskInfoList.length;i++){
                  $("#taskSubType").append("<option value='"+data.taskInfoList[i].taskSubType+"'>"+data.taskInfoList[i].taskSubTypeDesc+"</option>");
                }
              
                }
            });

           
</script>
</body>
</html>